﻿<?php
include_once("../../includes/metodos.php");
include_once("action.php");

connectSQL();
checkUser();
isAdmin();
include("../cabecalho.php");

if(!empty($_POST['cmd']) && $_POST['cmd']=='edit'){
	edit($_POST['id']);
}

$query = mysql_query("SELECT * FROM econ_institucional WHERE id=1");
$row = mysql_fetch_array($query);
$conteudo = $row['conteudo'];
$id = $row['id'];
?>
<div id="fundo">
   <div id="conteudo">
	   <div id="cabecalho">
		   	  <div style="margin:0 auto;width:696px;">
		   	    <br>
				<form action="index.php" method="post">
					<label style="color:#4CB74C;float:left;font: bold 16px verdana,arial,helvetica,sans-aerif;">Conte&uacute;do:</label><br><br>
					<textarea rows="" cols="" name="conteudo"> <?php echo $conteudo;?> </textarea>
					<input type="hidden" name="cmd" value="edit"/>
					<input type="hidden" name="id" value="<?php echo $id;?>"><br>
					<input id="nova_noticia" type="submit" value="Editar">
				</form>
			  </div>
		</div>
	</div>
</div>